<template>
  <div>首页

    <el-button @click="btnClick">调用登录接口post</el-button>
    <el-button @click="btnClick2">调用登录接口get</el-button>

  </div>
</template>
<script>
import { login, captchaLogin } from '@/api/test'
export default {
  methods: {
    async  btnClick() {
      const res = await login({
        'phone': '18511111111',
        'password': '12345678',
        'code': '1234'
      })
      console.log(res)
    },
    async btnClick2() {
      const res = await captchaLogin()
      console.log(res)
    }
  }
}
</script>
<style></style>
